//
//  MYXRechargeTopView.m
//  meiyinxiang
//
//  Created by 陈李飞 on 2017/11/10.
//  Copyright © 2017年 hbjApple. All rights reserved.
//

#import "MYXRechargeTopView.h"

@implementation MYXRechargeTopView
- (void)awakeFromNib{
     [super awakeFromNib];
     [self.moneyTF setValue:[UIColor whiteColor] forKeyPath:@"_placeholderLabel.textColor"];
    self.moneyTF.textAlignment = 1;
    [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(textfieldChanged) name:UITextFieldTextDidChangeNotification object:self.moneyTF];
}
- (void)textfieldChanged{
    CGFloat moneyNum = self.moneyTF.text.floatValue;
    if (moneyNum > 0 && moneyNum < 0.1) {
        self.moneyTF.text = @"0.10";
        ShowSVProgressErrorMessage(@"您好充值金额不能低于0.1元");
      //  [SVProgressHUD showErrorWithStatus:@"您好充值金额不能低于0.1元"];
    }
}
- (void)dealloc{
    [[NSNotificationCenter defaultCenter] removeObserver:self];
}
/*
// Only override drawRect: if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
- (void)drawRect:(CGRect)rect {
    // Drawing code
}
*/

@end
